﻿using System;

namespace MessagePack.Decoders
{
	// Token: 0x02000074 RID: 116
	internal class InvalidMapHeader : IMapHeaderDecoder
	{
		// Token: 0x0600021F RID: 543 RVA: 0x0000B11F File Offset: 0x0000951F
		private InvalidMapHeader()
		{
		}

		// Token: 0x06000220 RID: 544 RVA: 0x0000B127 File Offset: 0x00009527
		public uint Read(byte[] bytes, int offset, out int readSize)
		{
			throw new InvalidOperationException(string.Format("code is invalid. code:{0} format:{1}", bytes[offset], MessagePackCode.ToFormatName(bytes[offset])));
		}

		// Token: 0x0400009F RID: 159
		internal static readonly IMapHeaderDecoder Instance = new InvalidMapHeader();
	}
}
